package fr.cephb.locustree.loaders;

import java.util.HashMap;
import java.util.Map;

import fr.cephb.locustree.MappedObject;

public class UCSCAllMrnaLoader
	extends AbstractLTStreamLoader
	{
	@Override
	protected boolean make(String[] token)
		{
		this.chromosome=token[14];
		this.mappedObject=new MappedObject(
				token[10], token[10],
				Integer.parseInt(token[16]),
				Integer.parseInt(token[17])
				);
		Map<String,Object> json= new HashMap<String,Object>();
		json.put("strand", token[9]);
		json.put("tStarts", listOfInt(token[21]));
		json.put("blockSizes", listOfInt(token[19]));
		this.mappedObject.setJSON(json);
		this.keywords.add(this.mappedObject.getName());
		return true;
		}
	}
